<%
Dim action
action = Request.QueryString("action")
Randomize
Select Case action
    Case "post"
        post()
    Case Else
        Echo("1")
End Select

Function Echo(Str)
    Response.Write Str
End Function

Function post()
	Dim user, pass, ans
	user = unescape(Request("username"))
	pass = unescape(Request("password"))
	' Echo(user & " " & pass)
	ans = Int(Rnd * 10) Mod 2
	If ans = 1 Then
		Response.Cookies("noj_cookies")("username") = user
		Response.Cookies("noj_cookies").Expires = (now() + 7)
		Echo("1")
	Else
		Response.Cookies("noj_cookies").Expires = (now() - 1)
		Echo("0")
	End If
End Function
%>